package com.zsc.rediscli;

import redis.clients.jedis.Jedis;

public class RedisTest {
    public static void main(String[] args) {
        // 1.生成一个jedis对象，负责和redis通讯  public Jedis(String host, int port, int connectionTimeout, int soTimeout)
        // connectionTimeout 连接超时   soTimeout读写超时
        Jedis jedis = new Jedis("192.168.56.101", 6379);
        // jedis执行set操作
        jedis.set("hello","你还");
        // get操作
        String hello = jedis.get("hello");
    }
}
